
import { Input, Space, Button} from 'antd';
import { PlusSquareOutlined } from '@ant-design/icons'

const { Search } = Input;
export const ComSearch = ({ onAdd }) => {
  const onSearch = (value) => console.log(value);

  return <Space.Compact className='com-search'>
    <Search size='small' placeholder="请输入" onSearch={onSearch} enterButton />
    <Button title='新建' size='small' type="primary" icon={<PlusSquareOutlined />} onClick={onAdd}/>
  </Space.Compact>
}